home *** CD-ROM | disk | FTP | other *** search
/ Monster Media 1996 #14 / Monster Media No. 14 (April 1996) (Monster Media, Inc.).ISO / os2 / mroids09.zip / INSTALL.CMD < prev    next >
OS/2 REXX Batch file  |  1996-01-21  |  15KB  |  401 lines

  1. /* MASTERROIDS Installation Program */
  2.  
  3. call  RxFuncAdd "SysLoadFuncs","RexxUtil","SysLoadFuncs"
  4. call SysLoadFuncs
  5.  
  6.  
  7. '@echo off'
  8.  
  9.  
  10. Say " "
  11. Say "MASTERROIDS installation program ..."
  12. Say " "
  13. Say "DON'T PANIC :"
  14. Say "       This program doesn't write into any ini-file of your system"
  15. Say "       Also you DON'T have to change your CONFIG.SYS "
  16. Say "       ( and I also will not touch it :-)"
  17. Say " "
  18.  
  19. /* Is everything at its place */
  20.  
  21. Say "I'm checking if all files are present ..."
  22.  
  23. Result=SysFileTree("ALIEN.WAV", 'Files','F')
  24. If Files.0=0 Then
  25.         Do
  26.                 Say "Can't find FILE : ALIEN.WAV - make sure you unpacked all files ..."
  27.                 Say " "
  28.                 Say "Continuing with installation "
  29.                 Say " "
  30.         End
  31. Result=SysFileTree("CRASH.WAV", 'Files','F')
  32. If Files.0=0 Then
  33.         Do
  34.                 Say "Can't find FILE : CRASH.WAV - make sure you unpacked all files ..."
  35.                 Say " "
  36.                 Say "Continuing with installation "
  37.                 Say " "
  38.         End
  39. Result=SysFileTree("DANGER.WAV", 'Files','F')
  40. If Files.0=0 Then
  41.         Do
  42.                 Say "Can't find FILE : DANGER.WAV - make sure you unpacked all files ..."
  43.                 Say " "
  44.                 Say "Continuing with installation "
  45.                 Say " "
  46.         End
  47. Result=SysFileTree("DESTROY.WAV", 'Files','F')
  48. If Files.0=0 Then
  49.         Do
  50.                 Say "Can't find FILE : DESTROY.WAV - make sure you unpacked all files ..."
  51.                 Say " "
  52.                 Say "Continuing with installation "
  53.                 Say " "
  54.         End
  55. Result=SysFileTree("DIESHLDX.WAV", 'Files','F')
  56. If Files.0=0 Then
  57.         Do
  58.                 Say "Can't find FILE : DIESHLDX.WAV - make sure you unpacked all files ..."
  59.                 Say " "
  60.                 Say "Continuing with installation "
  61.                 Say " "
  62.         End
  63. Result=SysFileTree("DISAPPR.WAV", 'Files','F')
  64. If Files.0=0 Then
  65.         Do
  66.                 Say "Can't find FILE : DISAPPR.WAV - make sure you unpacked all files ..."
  67.                 Say " "
  68.                 Say "Continuing with installation "
  69.                 Say " "
  70.         End
  71. Result=SysFileTree("ENEMY.WAV", 'Files','F')
  72. If Files.0=0 Then
  73.         Do
  74.                 Say "Can't find FILE : ENEMY.WAV - make sure you unpacked all files ..."
  75.                 Say " "
  76.                 Say "Continuing with installation "
  77.                 Say " "
  78.         End
  79. Result=SysFileTree("ESPEED.WAV", 'Files','F')
  80. If Files.0=0 Then
  81.         Do
  82.                 Say "Can't find FILE : ESPEED.WAV - make sure you unpacked all files ..."
  83.                 Say " "
  84.                 Say "Continuing with installation "
  85.                 Say " "
  86.         End
  87. Result=SysFileTree("EXPLODE.WAV", 'Files','F')
  88. If Files.0=0 Then
  89.         Do
  90.                 Say "Can't find FILE : EXPLODE.WAV - make sure you unpacked all files ..."
  91.                 Say " "
  92.                 Say "Continuing with installation "
  93.                 Say " "
  94.         End
  95. Result=SysFileTree("EXTRA.WAV", 'Files','F')
  96. If Files.0=0 Then
  97.         Do
  98.                 Say "Can't find FILE : EXTRA.WAV - make sure you unpacked all files ..."
  99.                 Say " "
  100.                 Say "Continuing with installation "
  101.                 Say " "
  102.         End
  103. Result=SysFileTree("HITSTEEL.WAV", 'Files','F')
  104. If Files.0=0 Then
  105.         Do
  106.                 Say "Can't find FILE : HITSTEEL.WAV - make sure you unpacked all files ..."
  107.                 Say " "
  108.                 Say "Continuing with installation "
  109.                 Say " "
  110.         End
  111. Result=SysFileTree("HYPER.WAV", 'Files','F')
  112. If Files.0=0 Then
  113.         Do
  114.                 Say "Can't find FILE : HYPER.WAV - make sure you unpacked all files ..."
  115.                 Say " "
  116.                 Say "Continuing with installation "
  117.                 Say " "
  118.         End
  119. Result=SysFileTree("LASER.WAV", 'Files','F')
  120. If Files.0=0 Then
  121.         Do
  122.                 Say "Can't find FILE : LASER.WAV - make sure you unpacked all files ..."
  123.                 Say " "
  124.                 Say "Continuing with installation "
  125.                 Say " "
  126.         End
  127. Result=SysFileTree("NEWEXTRA.WAV", 'Files','F')
  128. If Files.0=0 Then
  129.         Do
  130.                 Say "Can't find FILE : NEWEXTRA.WAV - make sure you unpacked all files ..."
  131.                 Say " "
  132.                 Say "Continuing with installation "
  133.                 Say " "
  134.         End
  135. Result=SysFileTree("NEWLIFE.WAV", 'Files','F')
  136. If Files.0=0 Then
  137.         Do
  138.                 Say "Can't find FILE : NEWLIFE.WAV - make sure you unpacked all files ..."
  139.                 Say " "
  140.                 Say "Continuing with installation "
  141.                 Say " "
  142.         End
  143. Result=SysFileTree("SHIELD.WAV", 'Files','F')
  144. If Files.0=0 Then
  145.         Do
  146.                 Say "Can't find FILE : SHIELD.WAV - make sure you unpacked all files ..."
  147.                 Say " "
  148.                 Say "Continuing with installation "
  149.                 Say " "
  150.         End
  151. Result=SysFileTree("SHLDOFF.WAV", 'Files','F')
  152. If Files.0=0 Then
  153.         Do
  154.                 Say "Can't find FILE : SHLDOFF.WAV - make sure you unpacked all files ..."
  155.                 Say " "
  156.                 Say "Continuing with installation "
  157.                 Say " "
  158.         End
  159. Result=SysFileTree("SHLDON.WAV", 'Files','F')
  160. If Files.0=0 Then
  161.         Do
  162.                 Say "Can't find FILE : SHLDON.WAV - make sure you unpacked all files ..."
  163.                 Say " "
  164.                 Say "Continuing with installation "
  165.                 Say " "
  166.         End
  167. Result=SysFileTree("SHOT.WAV", 'Files','F')
  168. If Files.0=0 Then
  169.         Do
  170.                 Say "Can't find FILE : SHOT.WAV - make sure you unpacked all files ..."
  171.                 Say " "
  172.                 Say "Continuing with installation "
  173.                 Say " "
  174.         End
  175. Result=SysFileTree("TAKEPRTC.WAV", 'Files','F')
  176. If Files.0=0 Then
  177.         Do
  178.                 Say "Can't find FILE : TAKEPRTC.WAV - make sure you unpacked all files ..."
  179.                 Say " "
  180.                 Say "Continuing with installation "
  181.                 Say " "
  182.         End
  183. Result=SysFileTree("TAKESHLD.WAV", 'Files','F')
  184. If Files.0=0 Then
  185.         Do
  186.                 Say "Can't find FILE : TAKESHLD.WAV - make sure you unpacked all files ..."
  187.                 Say " "
  188.                 Say "Continuing with installation "
  189.                 Say " "
  190.         End
  191. Result=SysFileTree("WARP.WAV", 'Files','F')
  192. If Files.0=0 Then
  193.         Do
  194.                 Say "Can't find FILE : WARP.WAV - make sure you unpacked all files ..."
  195.                 Say " "
  196.                 Say "Continuing with installation "
  197.                 Say " "
  198.         End
  199. Result=SysFileTree("INSTALL.CMD", 'Files','F')
  200. If Files.0=0 Then
  201.         Do
  202.                 Say "Can't find FILE : INSTALL.CMD - make sure you unpacked all files ..."
  203.                 Say " "
  204.                 Say "Continuing with installation "
  205.                 Say " "
  206.         End
  207. Result=SysFileTree("MROIDS.EXE", 'Files','F')
  208. If Files.0=0 Then
  209.         Do
  210.                 Say "Can't find FILE : MROIDS.EXE - make sure you unpacked all files ..."
  211.                 Signal DONE
  212.         End
  213. Result=SysFileTree("MROIDS.ICO", 'Files','F')
  214. If Files.0=0 Then
  215.         Do
  216.                 Say "Can't find FILE : MROIDS.ICO - make sure you unpacked all files ..."
  217.                 Say " "
  218.                 Say "Continuing with installation "
  219.                 Say " "
  220.         End
  221. Result=SysFileTree("MROIDS.DIG", 'Files','F')
  222. If Files.0=0 Then
  223.         Do
  224.                 Say "Can't find FILE : MROIDS.DIG - make sure you unpacked all files ..."
  225.                 Signal DONE
  226.         End
  227. Result=SysFileTree("MROIDS.PIC", 'Files','F')
  228. If Files.0=0 Then
  229.         Do
  230.                 Say "Can't find FILE : MROIDS.PIC - make sure you unpacked all files ..."
  231.                 Signal DONE
  232.         End
  233. Result=SysFileTree("MROIDS.CMT", 'Files','F')
  234. If Files.0=0 Then
  235.         Do
  236.                 Say "Can't find FILE : MROIDS.CMT - make sure you unpacked all files ..."
  237.                 Signal DONE
  238.         End
  239. Result=SysFileTree("MRRESET.EXE", 'Files','F')
  240. If Files.0=0 Then
  241.         Do
  242.                 Say "Can't find FILE : MRRESET.EXE - make sure you unpacked all files ..."
  243.                 Say "Without this program you cannot reset the MROIDS.INI file to uncritical"
  244.                 Say "values if you have changed something in the configuration of MASTERROIDS"
  245.                 Say "and then the game crashes every time you try to start it."
  246.                 Say "This occurs, when you are using MMPM or the palette manager but you don't"
  247.                 Say "have installed MMPM or your OS/2-system has no palette manager."
  248.                 Say "See the README.1ST for more information."
  249.                 Say " "
  250.                 Say "Continuing with installation "
  251.                 Say " "
  252.         End
  253. Result=SysFileTree("WAVE.DLL", 'Files','F')
  254. If Files.0=0 Then
  255.         Do
  256.                 Say "Can't find FILE : WAVE.DLL - make sure you unpacked all files ..."
  257.                 Say "Without this DLL you won't be able to here any sounds while playing."
  258.                 Say " "
  259.                 Say "Continuing with installation "
  260.                 Say " "
  261.         End
  262. Result=SysFileTree("WAVEINFO.EXE", 'Files','F')
  263. If Files.0=0 Then
  264.         Do
  265.                 Say "Can't find FILE : WAVEINFO.EXE - make sure you unpacked all files ..."
  266.                 Say " "
  267.                 Say "Continuing with installation "
  268.                 Say " "
  269.         End
  270. Result=SysFileTree("README.1ST", 'Files','F')
  271. If Files.0=0 Then
  272.         Do
  273.                 Say "Can't find FILE : README.1ST - make sure you unpacked all files ..."
  274.                 Say "This file is very important - it tells you how to register :-)"
  275.                 Signal DONE
  276.         End
  277. Result=SysFileTree("ORDER.FRM", 'Files','F')
  278. If Files.0=0 Then
  279.         Do
  280.                 Say "Can't find FILE : ORDER.FRM - make sure you unpacked all files ..."
  281.                 Say "This file is very important - it tells you how to register :-)"
  282.                 Signal DONE
  283.         End
  284. Result=SysFileTree("EMX.DLL", 'Files','F')
  285. If Files.0=0 Then
  286.         Do
  287.                 Say "Can't find FILE : EMX.DLL "
  288.                 Say "I hope you have this file in your LIBPATH, else the program won't run"
  289.                 Say "If you can't start MASTERROIDS : "
  290.                 Say "   unpack EMX.DLL into your LIBPATH or MASTERROIDSs working-directory"
  291.                 Say " "
  292.                 Say "Continuing with installation "
  293.                 Say " "
  294.         End
  295. Say "All neccessary files found ...Ok"
  296.  
  297. Say " "
  298. Say "Do you want me to copy the files to another directory ?"
  299. Say "       This directory does NOT need to be specified in any of your paths"
  300. Say "(Y/N) ? ( Default = N )"
  301. Pull YesNo
  302. If YesNo="Y" Then
  303. Do
  304.         Say " "
  305.         Say "Please enter the full path of the desired directory ..."
  306.         Pull Directory
  307.         Result=SysFileTree(Directory,'Dirs','D')
  308.         /*
  309.         if Dirs.0=0 Then
  310.         */
  311.         Do
  312.                 if Dirs.0=0 then
  313.                 Do
  314.                    If SysMkDir(Directory) then
  315.                    Do
  316.                         Say "ERROR : Can't CREATE your desired directory"
  317.                         Signal DONE
  318.                    End
  319.                    else
  320.                    do
  321.                       say "Directory" Directory "created. Ok."
  322.                    end
  323.                 End
  324.                 /* Copying Files*/
  325.                 Say "Copying..."
  326.  
  327.                 Copy "ALIEN.WAV" Directory   '1>NUL'
  328.                 Copy "CRASH.WAV" Directory   '1>NUL'
  329.                 Copy "DANGER.WAV" Directory   '1>NUL'
  330.                 Copy "DESTROY.WAV" Directory   '1>NUL'
  331.                 Copy "DIESHLDX.WAV" Directory   '1>NUL'
  332.                 Copy "DISAPPR.WAV" Directory   '1>NUL'
  333.                 Copy "ENEMY.WAV" Directory   '1>NUL'
  334.                 Copy "ESPEED.WAV" Directory   '1>NUL'
  335.                 Copy "EXPLODE.WAV" Directory   '1>NUL'
  336.                 Copy "EXTRA.WAV" Directory   '1>NUL'
  337.                 Copy "HITSTEEL.WAV" Directory   '1>NUL'
  338.                 Copy "HYPER.WAV" Directory   '1>NUL'
  339.                 Copy "LASER.WAV" Directory   '1>NUL'
  340.                 Copy "NEWEXTRA.WAV" Directory   '1>NUL'
  341.                 Copy "NEWLIFE.WAV" Directory   '1>NUL'
  342.                 Copy "SHIELD.WAV" Directory   '1>NUL'
  343.                 Copy "SHLDOFF.WAV" Directory   '1>NUL'
  344.                 Copy "SHLDON.WAV" Directory   '1>NUL'
  345.                 Copy "SHOT.WAV" Directory   '1>NUL'
  346.                 Copy "TAKEPRTC.WAV" Directory   '1>NUL'
  347.                 Copy "TAKESHLD.WAV" Directory   '1>NUL'
  348.                 Copy "WARP.WAV" Directory   '1>NUL'
  349.                 Copy "INSTALL.CMD" Directory   '1>NUL'
  350.                 Copy "MROIDS.EXE" Directory   '1>NUL'
  351.                 Copy "MROIDS.ICO" Directory   '1>NUL'
  352.                 Copy "MROIDS.DIG" Directory   '1>NUL'
  353.                 Copy "MROIDS.PIC" Directory   '1>NUL'
  354.                 Copy "MROIDS.CMT" Directory   '1>NUL'
  355.                 Copy "MRRESET.EXE" Directory   '1>NUL'
  356.                 Copy "WAVE.DLL" Directory   '1>NUL'
  357.                 Copy "WAVEINFO.EXE" Directory   '1>NUL'
  358.                 Copy "README.1ST" Directory   '1>NUL'
  359.                 Copy "ORDER.FRM" Directory   '1>NUL'
  360.                 Copy "EMX.DLL" Directory   '1>NUL'
  361.  
  362.                 say "Ok."
  363.         End
  364. End
  365. Else
  366. Do
  367.         Directory=Directory()
  368. End
  369.  
  370. Say " "
  371. Say "Do you want me to create a program object ...?"
  372. Say "(Y/N) ? ( Default = Y )"
  373. Pull YesNo
  374. If YesNo="N" Then   Signal ENDE
  375. Else
  376.         Do
  377.                 Folder="<WP_DESKTOP>" 
  378.                 Type="WPProgram"
  379.                 Title="MASTERROIDS"
  380.                 Params="EXENAME="Directory"\MROIDS.EXE;STARTUPDIR="Directory";"
  381.                 If SysCreateObject(Type,Title,Folder,Params,"ReplaceIfExists") Then
  382.                 Do
  383.                         Say " "
  384.                         Say "MASTERROIDS Program object created successfully !"
  385.                 End
  386.                 Else
  387.                 Do
  388.                         Say "Could't create MASTERROIDS Program object."
  389.                         Signal DONE
  390.                 End
  391.  
  392.         End
  393. ENDE:
  394. Say " "
  395. Say " To start the game simply type MROIDS "
  396. Say " "
  397. Say " HAVE FUN WITH MASTERROIDS V0.9"
  398. Say " "
  399. DONE:
  400. Exit
  401.